package com.msh.platform.elm.entity;

import javax.persistence.*;

import io.swagger.annotations.ApiModelProperty;

import java.util.Objects;

@Entity
@Table(name = "wx_pub_no_exam", schema = "mscm_dev", catalog = "")
public class WxPubNoExam {
    private int id;
    @ApiModelProperty(value="公众号名称")
    private String name;
	@ApiModelProperty(value="头像地址")
    private String avatar;
	@ApiModelProperty(value="详细介绍")
    private String detail;
	@ApiModelProperty(value="微信号")
    private String acctNo;
	@ApiModelProperty(value="粉丝数")
    private Integer fansCnt;
	@ApiModelProperty(value="二维码图片地址")
    private String qrCodeUrl;
	@ApiModelProperty(value="公众号类型")
    private String type;

    @Id
    @Column(name = "ID")
    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    @Basic
    @Column(name = "NAME")
    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    @Basic
    @Column(name = "avatar")
    public String getAvatar() {
        return avatar;
    }

    public void setAvatar(String avatar) {
        this.avatar = avatar;
    }

    @Basic
    @Column(name = "detail")
    public String getDetail() {
        return detail;
    }

    public void setDetail(String detail) {
        this.detail = detail;
    }

    @Basic
    @Column(name = "FANS_cnt")
    public Integer getFansCnt() {
        return fansCnt;
    }

    public void setFansCnt(Integer fansCnt) {
        this.fansCnt = fansCnt;
    }

    @Basic
    @Column(name = "acct_no")
    public String getAcctNo() {
        return acctNo;
    }

    public void setAcctNo(String acctNo) {
        this.acctNo = acctNo;
    }

    @Basic
    @Column(name = "QR_CODE_url")
    public String getQrCodeUrl() {
        return qrCodeUrl;
    }

    public void setQrCodeUrl(String qrCodeUrl) {
        this.qrCodeUrl = qrCodeUrl;
    }

    @Basic
    @Column(name = "TYPE")
    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        WxPubNoExam wxPubNo = (WxPubNoExam) o;
        return id == wxPubNo.id &&
                Objects.equals(name, wxPubNo.name) &&
                Objects.equals(avatar, wxPubNo.avatar) &&
                Objects.equals(detail, wxPubNo.detail) &&
                Objects.equals(fansCnt, wxPubNo.fansCnt) &&
                Objects.equals(acctNo, wxPubNo.acctNo) &&
                Objects.equals(qrCodeUrl, wxPubNo.qrCodeUrl) &&
                Objects.equals(type, wxPubNo.type);
    }

    @Override
    public int hashCode() {

        return Objects.hash(id, name, avatar, detail, fansCnt, acctNo, qrCodeUrl, type);
    }
}
